package com.yang.design_principle.liskov_substitution_principle;

import org.omg.CORBA.Request;
import sun.net.www.http.HttpClient;

import javax.xml.ws.Response;

/**
 * @Description: 传输数据
 * @Author: 杨 强
 * @CreateTime: 2022-10-11 16:24
 */
public class Transporter {
    /**
     * HttpClient来传输数据
     */
    private HttpClient httpClient;

    /**
     * 构造注入
     * @param httpClient
     */
    public Transporter(HttpClient httpClient) {
        this.httpClient = httpClient;
    }

    /**
     * 传输问网络数据
     * @param request
     * @return
     */
    public Response sendRequest(Request request) {
        // ...use httpClient to send request
        return null;
    }
}
